/**
 * 先判断数量，再改大小写
 */
#include <bits/stdc++.h>
using namespace std;

string S;

void work(){
    cin >> S;
    int cnt = 0;
    int n = S.length();
    for(auto c : S)if(isupper(c))cnt+=1;
    if(cnt > n - cnt){
        for(auto & c : S)if(islower(c))c-=32;
    }else{
        for(auto & c : S)if(isupper(c))c+=32;
    }
    cout << S << endl;
    return;
}

int main(){
#ifndef ONLINE_JUDGE
    freopen("z.txt", "r", stdin);
#endif
    ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
    int nofkase = 1;
    // cin >> nofkase; 
    while(nofkase--) work();
    return 0;
}